<!DOCTYPE html>
<html lang="zh" xmlns:th="http://www.thymeleaf.org" >
<head>
    <th:block th:include="include :: header('新增指标信息')" />
</head>
<body class="white-bg">
    <div class="wrapper wrapper-content animated fadeInRight ibox-content">
        <form class="form-horizontal m" id="form-index-add">
            <div class="form-group">
                <label class="col-sm-3 control-label">系统：</label>
                <div class="col-sm-8">
                    <select name="sdSys" class="form-control m-b" th:with="type=${@baseSd.getItem('hos_sys')}">
                        <option th:each="item : ${type}" th:text="${item.na}" th:value="${item.cd}"></option>
                    </select>
                </div>
            </div>
            <div class="form-group">
                <label class="col-sm-3 control-label">指标编码：</label>
                <div class="col-sm-8">
                    <div class="input-group m-b"><span class="input-group-addon">IDX_HIS_</span>
                        <input type="text" class="form-control">
                        <span class="input-group-addon">_RC</span>
                    </div>
                    <!--<input name="idIndex" class="form-control" type="text">-->
                </div>
            </div>
            <div class="form-group">
                <label class="col-sm-3 control-label">指标名称：</label>
                <div class="col-sm-8">
                    <input name="na" class="form-control" type="text">
                </div>
            </div>
            <div class="form-group">
                <label class="col-sm-3 control-label">口径：</label>
                <div class="col-sm-8">
                    <textarea name="instr" class="form-control"></textarea>
                </div>
            </div>
            <div class="form-group">    
                <label class="col-sm-3 control-label">指标类型：</label>
                <div class="col-sm-8">
                    <select name="euTp" class="form-control m-b">
                        <option value=0>原子指标</option>
                        <option value=1>复合指标</option>
                        <option value=2>子指标</option>
                    </select>
                </div>
            </div>
            <div class="form-group">    
                <label class="col-sm-3 control-label">累加标志：</label>
                <div class="col-sm-8">
                    <select name="fgAccu" class="form-control m-b">
                        <option value=1>是</option>
                        <option value=0>否</option>
                    </select>
                </div>
            </div>
            <!--<div class="form-group">
                <label class="col-sm-3 control-label">值类型：</label>
                <div class="col-sm-8">
                    <select name="sdValtp" class="form-control m-b" th:with="type=${@baseSd.getItem('index_valtp')}">
                        <option th:each="item : ${type}" th:text="${item.na}" th:value="${item.cd}"></option>
                    </select>
                </div>
            </div>-->
            <div class="form-group">
                <label class="col-sm-3 control-label">单位：</label>
                <div class="col-sm-8">
                    <input name="unit" class="form-control" type="text">
                </div>
            </div>
            <div class="form-group">    
                <label class="col-sm-3 control-label">备注：</label>
                <div class="col-sm-8">
                    <input name="des" class="form-control" type="text">
                </div>
            </div>
        </form>
    </div>
    <th:block th:include="include :: footer" />
    <script th:inline="javascript">
        var prefix = ctx + "md/index/index"
        $("#form-index-add").validate({
            focusCleanup: true
        });

        function submitHandler() {
            if ($.validate.form()) {
                $.operate.save(prefix + "/add", $('#form-index-add').serialize());
            }
        }
    </script>
</body>
</html>